package fr.ece.ing4.javafinance.lab1;

public class Outer {
	private String greeting;

	protected class Inner {
		public String greeting = "Hello, Inner";
		public int repeat = 3;

		public void go() {
			for (int i = 1; i <= repeat; i++) {
				System.out.println(Outer.this.greeting);
			}
		}
	}

	public void displayGreeting() {
		Outer.Inner x = this.new Inner();
		x.repeat = 2;
		x.go();
	}

	public static void main(String[] args) {
		Outer y = new Outer();
		y.greeting = "Hello, Outer";
		y.displayGreeting();
	}
}
